#ifndef __HEAD__
#define __HEAD__
#include <header.h>

enum TYPE{
    DATA,
    CD,
    LS,
    PUTS,
    GETS,
    REMOVE,
    PWD,
    MKDIR
};

typedef struct train_s{
    int type;
    int len;
    char data[1000];
}train_t;
//用于从配置文件中获取参数
/* int conf_get(char *conf,char *ip,char *port); */
//建立TCP链接
int tcp_Init(char *ip,char *port);

/* int upload(int sockfd,char *filename); */
/* int download(int sockfd,char * filename); */

int send_cmd(char *line,int sockfd);
int check_cmd(char *line);

#endif
